package com.nineclock.system.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.nineclock.system.pojo.SysCompanyUserRole;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Update;


/**
 * @author 黑马程序员
 * @Company http://www.ithiema.com
 * @Version 1.0
 */
@Mapper
public interface SysCompanyUserRoleMapper extends BaseMapper<SysCompanyUserRole> {


    @Update("UPDATE sys_company_user_role SET" +
            " company_user_id=#{companyUserRole.getRoleId}, role_id=#{companyUserRole.getRoleId()} WHERE company_id=#{companyUserRole.getCompanyId()}")
    SysCompanyUserRole  upByid(@Param("companyUserRole") SysCompanyUserRole companyUserRole);

}
